package main

import (
	"fmt"
	"os"
	"strings"
)

func main() {
	file, err := os.ReadFile("./gamelogic/user_gm.go")
	if err != nil {
		panic(err)
	}
	lineList := strings.Split(string(file), "\n")
	for index, line := range lineList {
		if strings.Contains(line, "func (g *GMCmd) GM") {
			fmt.Println(strings.ReplaceAll(strings.ReplaceAll(line, "func (g *GMCmd) ", ""), " {", "") + " // " + strings.Split(lineList[index-1], " ")[2])
		}
	}
}
